﻿using UnityEngine;
using System.Collections;

public class ResizeNGUI : MonoBehaviour {

	public Camera baseCamera;

	// Use this for initialization
	void Start () {
		UIRoot root = GetComponent<UIRoot>();
		float ar = baseCamera.aspect;

		//1.33333
		if(ar > 1.2f && ar < 1.4f)
		{
			root.manualHeight = 1368;
		}
		else if(ar > 1.5 && ar < 1.7f)
		{
			root.manualHeight = 1140;
		}
		//1.77778
		else
		{
			root.manualHeight = 1024;
		}
	}
	
	// Update is called once per frame
	void Update () {
	
	}
}
